[−][src]Crate lightgbm_sys
Structs
_G_fpos64_t | |
_G_fpos_t | |
_IO_FILE | |
_IO_codecvt | |
_IO_cookie_io_functions_t | |
_IO_marker | |
_IO_wide_data | |
__fsid_t | |
__locale_data | |
__locale_struct | |
__mbstate_t | |
__va_list_tag | |
obstack |
Constants
Statics
_sys_errlist | |
_sys_nerr | |
stderr | |
stdin | |
stdout | |
sys_errlist | |
sys_nerr |
Functions
LGBM_BoosterAddValidData⚠ | \brief Add new validation data to booster. \param handle Handle of booster \param valid_data Validation dataset \return 0 when succeed, -1 when failure happens |
LGBM_BoosterCalcNumPredict⚠ | \brief Get number of predictions. \param handle Handle of booster \param num_row Number of rows \param predict_type What should be predicted |
LGBM_BoosterCreate⚠ | \brief Create a new boosting learner. \param train_data Training dataset \param parameters Parameters in format 'key1=value1 key2=value2' \param[out] out Handle of created booster \return 0 when succeed, -1 when failure happens |
LGBM_BoosterCreateFromModelfile⚠ | \brief Load an existing booster from model file. \param filename Filename of model \param[out] out_num_iterations Number of iterations of this booster \param[out] out Handle of created booster \return 0 when succeed, -1 when failure happens |
LGBM_BoosterDumpModel⚠ | \brief Dump model to JSON.
\param handle Handle of booster
\param start_iteration Start index of the iteration that should be dumped
\param num_iteration Index of the iteration that should be dumped, <= 0 means dump all
\param feature_importance_type Type of feature importance, can be |
LGBM_BoosterFeatureImportance⚠ | \brief Get model feature importance. \param handle Handle of booster \param num_iteration Number of iterations for which feature importance is calculated, <= 0 means use all \param importance_type Method of importance calculation: |
LGBM_BoosterFree⚠ | \brief Free space for booster. \param handle Handle of booster to be freed \return 0 when succeed, -1 when failure happens |
LGBM_BoosterFreePredictSparse⚠ | \brief Method corresponding to |
LGBM_BoosterGetCurrentIteration⚠ | \brief Get index of the current boosting iteration. \param handle Handle of booster \param[out] out_iteration Index of the current boosting iteration \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetEval⚠ | \brief Get evaluation for training data and validation data. \note |
LGBM_BoosterGetEvalCounts⚠ | \brief Get number of evaluation datasets. \param handle Handle of booster \param[out] out_len Total number of evaluation datasets \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetEvalNames⚠ | \brief Get names of evaluation datasets.
\param handle Handle of booster
\param len Number of |
LGBM_BoosterGetFeatureNames⚠ | \brief Get names of features.
\param handle Handle of booster
\param len Number of |
LGBM_BoosterGetLeafValue⚠ | \brief Get leaf value. \param handle Handle of booster \param tree_idx Index of tree \param leaf_idx Index of leaf \param[out] out_val Output result from the specified leaf \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetLinear⚠ | \brief Get boolean representing whether booster is fitting linear trees. \param handle Handle of booster \param[out] out The address to hold linear trees indicator \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetLowerBoundValue⚠ | \brief Get model lower bound value. \param handle Handle of booster \param[out] out_results Result pointing to min value \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetNumClasses⚠ | \brief Get number of classes. \param handle Handle of booster \param[out] out_len Number of classes \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetNumFeature⚠ | \brief Get number of features. \param handle Handle of booster \param[out] out_len Total number of features \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetNumPredict⚠ | \brief Get number of predictions for training data and validation data (this can be used to support customized evaluation functions). \param handle Handle of booster \param data_idx Index of data, 0: training data, 1: 1st validation data, 2: 2nd validation data and so on \param[out] out_len Number of predictions \return 0 when succeed, -1 when failure happens |
LGBM_BoosterGetPredict⚠ | \brief Get prediction for training data and validation data.
\note
You should pre-allocate memory for |
LGBM_BoosterGetUpperBoundValue⚠ | \brief Get model upper bound value. \param handle Handle of booster \param[out] out_results Result pointing to max value \return 0 when succeed, -1 when failure happens |
LGBM_BoosterLoadModelFromString⚠ | \brief Load an existing booster from string. \param model_str Model string \param[out] out_num_iterations Number of iterations of this booster \param[out] out Handle of created booster \return 0 when succeed, -1 when failure happens |
LGBM_BoosterMerge⚠ | \brief Merge model from |
LGBM_BoosterNumModelPerIteration⚠ | \brief Get number of trees per iteration. \param handle Handle of booster \param[out] out_tree_per_iteration Number of trees per iteration \return 0 when succeed, -1 when failure happens |
LGBM_BoosterNumberOfTotalModel⚠ | \brief Get number of weak sub-models. \param handle Handle of booster \param[out] out_models Number of weak sub-models \return 0 when succeed, -1 when failure happens |
LGBM_BoosterPredictForCSC⚠ | \brief Make prediction for a new dataset in CSC format.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictForCSR⚠ | \brief Make prediction for a new dataset in CSR format.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictForCSRSingleRow⚠ | \brief Make prediction for a new dataset in CSR format. This method re-uses the internal predictor structure
from previous calls and is optimized for single row invocation.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictForCSRSingleRowFast⚠ | \brief Faster variant of |
LGBM_BoosterPredictForCSRSingleRowFastInit⚠ | \brief Initialize and return a |
LGBM_BoosterPredictForFile⚠ | \brief Make prediction for file. \param handle Handle of booster \param data_filename Filename of file with data \param data_has_header Whether file has header or not \param predict_type What should be predicted |
LGBM_BoosterPredictForMat⚠ | \brief Make prediction for a new dataset.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictForMatSingleRow⚠ | \brief Make prediction for a new dataset. This method re-uses the internal predictor structure
from previous calls and is optimized for single row invocation.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictForMatSingleRowFast⚠ | \brief Faster variant of |
LGBM_BoosterPredictForMatSingleRowFastInit⚠ | \brief Initialize and return a |
LGBM_BoosterPredictForMats⚠ | \brief Make prediction for a new dataset presented in a form of array of pointers to rows.
\note
You should pre-allocate memory for |
LGBM_BoosterPredictSparseOutput⚠ | \brief Make sparse prediction for a new dataset in CSR or CSC format. Currently only used for feature contributions. \note The outputs are pre-allocated, as they can vary for each invocation, but the shape should be the same: |
LGBM_BoosterRefit⚠ | \brief Refit the tree model using the new data (online learning).
\param handle Handle of booster
\param leaf_preds Pointer to predicted leaf indices
\param nrow Number of rows of |
LGBM_BoosterResetParameter⚠ | \brief Reset config for booster. \param handle Handle of booster \param parameters Parameters in format 'key1=value1 key2=value2' \return 0 when succeed, -1 when failure happens |
LGBM_BoosterResetTrainingData⚠ | \brief Reset training data for booster. \param handle Handle of booster \param train_data Training dataset \return 0 when succeed, -1 when failure happens |
LGBM_BoosterRollbackOneIter⚠ | \brief Rollback one iteration. \param handle Handle of booster \return 0 when succeed, -1 when failure happens |
LGBM_BoosterSaveModel⚠ | \brief Save model into file.
\param handle Handle of booster
\param start_iteration Start index of the iteration that should be saved
\param num_iteration Index of the iteration that should be saved, <= 0 means save all
\param feature_importance_type Type of feature importance, can be |
LGBM_BoosterSaveModelToString⚠ | \brief Save model to string.
\param handle Handle of booster
\param start_iteration Start index of the iteration that should be saved
\param num_iteration Index of the iteration that should be saved, <= 0 means save all
\param feature_importance_type Type of feature importance, can be |
LGBM_BoosterSetLeafValue⚠ | \brief Set leaf value. \param handle Handle of booster \param tree_idx Index of tree \param leaf_idx Index of leaf \param val Leaf value \return 0 when succeed, -1 when failure happens |
LGBM_BoosterShuffleModels⚠ | \brief Shuffle models. \param handle Handle of booster \param start_iter The first iteration that will be shuffled \param end_iter The last iteration that will be shuffled \return 0 when succeed, -1 when failure happens |
LGBM_BoosterUpdateOneIter⚠ | \brief Update the model for one iteration. \param handle Handle of booster \param[out] is_finished 1 means the update was successfully finished (cannot split any more), 0 indicates failure \return 0 when succeed, -1 when failure happens |
LGBM_BoosterUpdateOneIterCustom⚠ | \brief Update the model by specifying gradient and Hessian directly (this can be used to support customized loss functions). \param handle Handle of booster \param grad The first order derivative (gradient) statistics \param hess The second order derivative (Hessian) statistics \param[out] is_finished 1 means the update was successfully finished (cannot split any more), 0 indicates failure \return 0 when succeed, -1 when failure happens |
LGBM_DatasetAddFeaturesFrom⚠ | \brief Add features from |
LGBM_DatasetCreateByReference⚠ | \brief Allocate the space for dataset and bucket feature bins according to reference dataset. \param reference Used to align bin mapper with other dataset \param num_total_row Number of total rows \param[out] out Created dataset \return 0 when succeed, -1 when failure happens |
LGBM_DatasetCreateFromCSC⚠ | \brief Create a dataset from CSC format.
\param col_ptr Pointer to column headers
\param col_ptr_type Type of |
LGBM_DatasetCreateFromCSR⚠ | \brief Create a dataset from CSR format.
\param indptr Pointer to row headers
\param indptr_type Type of |
LGBM_DatasetCreateFromCSRFunc⚠ | \brief Create a dataset from CSR format through callbacks.
\param get_row_funptr Pointer to |
LGBM_DatasetCreateFromFile⚠ | \brief Load dataset from file (like LightGBM CLI version does). \param filename The name of the file \param parameters Additional parameters \param reference Used to align bin mapper with other dataset, nullptr means isn't used \param[out] out A loaded dataset \return 0 when succeed, -1 when failure happens |
LGBM_DatasetCreateFromMat⚠ | \brief Create dataset from dense matrix.
\param data Pointer to the data space
\param data_type Type of |
LGBM_DatasetCreateFromMats⚠ | \brief Create dataset from array of dense matrices.
\param nmat Number of dense matrices
\param data Pointer to the data space
\param data_type Type of |
LGBM_DatasetCreateFromSampledColumn⚠ | \brief Allocate the space for dataset and bucket feature bins according to sampled data. \param sample_data Sampled data, grouped by the column \param sample_indices Indices of sampled data \param ncol Number of columns \param num_per_col Size of each sampling column \param num_sample_row Number of sampled rows \param num_total_row Number of total rows \param parameters Additional parameters \param[out] out Created dataset \return 0 when succeed, -1 when failure happens |
LGBM_DatasetDumpText⚠ | \brief Save dataset to text file, intended for debugging use only. \param handle Handle of dataset \param filename The name of the file \return 0 when succeed, -1 when failure happens |
LGBM_DatasetFree⚠ | \brief Free space for dataset. \param handle Handle of dataset to be freed \return 0 when succeed, -1 when failure happens |
LGBM_DatasetGetFeatureNames⚠ | \brief Get feature names of dataset.
\param handle Handle of dataset
\param len Number of |
LGBM_DatasetGetField⚠ | \brief Get info vector from dataset.
\param handle Handle of dataset
\param field_name Field name
\param[out] out_len Used to set result length
\param[out] out_ptr Pointer to the result
\param[out] out_type Type of result pointer, can be |
LGBM_DatasetGetNumData⚠ | \brief Get number of data points. \param handle Handle of dataset \param[out] out The address to hold number of data points \return 0 when succeed, -1 when failure happens |
LGBM_DatasetGetNumFeature⚠ | \brief Get number of features. \param handle Handle of dataset \param[out] out The address to hold number of features \return 0 when succeed, -1 when failure happens |
LGBM_DatasetGetSubset⚠ | \brief Create subset of a data.
\param handle Handle of full dataset
\param used_row_indices Indices used in subset
\param num_used_row_indices Length of |
LGBM_DatasetPushRows⚠ | \brief Push data to existing dataset, if |
LGBM_DatasetPushRowsByCSR⚠ | \brief Push data to existing dataset, if |
LGBM_DatasetSaveBinary⚠ | \brief Save dataset to binary file. \param handle Handle of dataset \param filename The name of the file \return 0 when succeed, -1 when failure happens |
LGBM_DatasetSetFeatureNames⚠ | \brief Save feature names to dataset. \param handle Handle of dataset \param feature_names Feature names \param num_feature_names Number of feature names \return 0 when succeed, -1 when failure happens |
LGBM_DatasetSetField⚠ | \brief Set vector to a content in info. \note |
LGBM_DatasetUpdateParamChecking⚠ | \brief Raise errors for attempts to update dataset parameters. \param old_parameters Current dataset parameters \param new_parameters New dataset parameters \return 0 when succeed, -1 when failure happens |
LGBM_FastConfigFree⚠ | \brief Release FastConfig object. |
LGBM_GetLastError⚠ | \brief Get string message of the last error. \return Error information |
LGBM_NetworkFree⚠ | \brief Finalize the network. \return 0 when succeed, -1 when failure happens |
LGBM_NetworkInit⚠ | \brief Initialize the network. \param machines List of machines in format 'ip1:port1,ip2:port2' \param local_listen_port TCP listen port for local machines \param listen_time_out Socket time-out in minutes \param num_machines Total number of machines \return 0 when succeed, -1 when failure happens |
LGBM_NetworkInitWithFunctions⚠ | \brief Initialize the network with external collective functions. \param num_machines Total number of machines \param rank Rank of local machine \param reduce_scatter_ext_fun The external reduce-scatter function \param allgather_ext_fun The external allgather function \return 0 when succeed, -1 when failure happens |
LGBM_RegisterLogCallback⚠ | \brief Register a callback function for log redirecting. \param callback The callback function to register \return 0 when succeed, -1 when failure happens |
__asprintf⚠ | |
__getdelim⚠ | |
__mempcpy⚠ | |
__overflow⚠ | |
__stpcpy⚠ | |
__stpncpy⚠ | |
__strtok_r⚠ | |
__uflow⚠ | |
asprintf⚠ | |
basename⚠ | |
bcmp⚠ | |
bcopy⚠ | |
bzero⚠ | |
clearerr⚠ | |
clearerr_unlocked⚠ | |
ctermid⚠ | |
cuserid⚠ | |
dprintf⚠ | |
explicit_bzero⚠ | |
fclose⚠ | |
fcloseall⚠ | |
fdopen⚠ | |
feof⚠ | |
feof_unlocked⚠ | |
ferror⚠ | |
ferror_unlocked⚠ | |
fflush⚠ | |
fflush_unlocked⚠ | |
ffs⚠ | |
ffsl⚠ | |
ffsll⚠ | |
fgetc⚠ | |
fgetc_unlocked⚠ | |
fgetpos⚠ | |
fgetpos64⚠ | |
fgets⚠ | |
fgets_unlocked⚠ | |
fileno⚠ | |
fileno_unlocked⚠ | |
flockfile⚠ | |
fmemopen⚠ | |
fopen⚠ | |
fopen64⚠ | |
fopencookie⚠ | |
fprintf⚠ | |
fputc⚠ | |
fputc_unlocked⚠ | |
fputs⚠ | |
fputs_unlocked⚠ | |
fread⚠ | |
fread_unlocked⚠ | |
freopen⚠ | |
freopen64⚠ | |
fscanf⚠ | |
fscanf1⚠ | |
fseek⚠ | |
fseeko⚠ | |
fseeko64⚠ | |
fsetpos⚠ | |
fsetpos64⚠ | |
ftell⚠ | |
ftello⚠ | |
ftello64⚠ | |
ftrylockfile⚠ | |
funlockfile⚠ | |
fwrite⚠ | |
fwrite_unlocked⚠ | |
getc⚠ | |
getc_unlocked⚠ | |
getchar⚠ | |
getchar_unlocked⚠ | |
getdelim⚠ | |
getline⚠ | |
gets⚠ | |
getw⚠ | |
index⚠ | |
memccpy⚠ | |
memchr⚠ | |
memcmp⚠ | |
memcpy⚠ | |
memfrob⚠ | |
memmem⚠ | |
memmove⚠ | |
mempcpy⚠ | |
memrchr⚠ | |
memset⚠ | |
obstack_printf⚠ | |
obstack_vprintf⚠ | |
open_memstream⚠ | |
pclose⚠ | |
perror⚠ | |
popen⚠ | |
printf⚠ | |
putc⚠ | |
putc_unlocked⚠ | |
putchar⚠ | |
putchar_unlocked⚠ | |
puts⚠ | |
putw⚠ | |
rawmemchr⚠ | |
remove⚠ | |
rename⚠ | |
renameat⚠ | |
renameat2⚠ | |
rewind⚠ | |
rindex⚠ | |
scanf⚠ | |
scanf1⚠ | |
setbuf⚠ | |
setbuffer⚠ | |
setlinebuf⚠ | |
setvbuf⚠ | |
snprintf⚠ | |
sprintf⚠ | |
sscanf⚠ | |
sscanf1⚠ | |
stpcpy⚠ | |
stpncpy⚠ | |
strcasecmp⚠ | |
strcasecmp_l⚠ | |
strcasestr⚠ | |
strcat⚠ | |
strchr⚠ | |
strchrnul⚠ | |
strcmp⚠ | |
strcoll⚠ | |
strcoll_l⚠ | |
strcpy⚠ | |
strcspn⚠ | |
strdup⚠ | |
strerror⚠ | |
strerror_l⚠ | |
strerror_r⚠ | |
strfry⚠ | |
strlen⚠ | |
strncasecmp⚠ | |
strncasecmp_l⚠ | |
strncat⚠ | |
strncmp⚠ | |
strncpy⚠ | |
strndup⚠ | |
strnlen⚠ | |
strpbrk⚠ | |
strrchr⚠ | |
strsep⚠ | |
strsignal⚠ | |
strspn⚠ | |
strstr⚠ | |
strtok⚠ | |
strtok_r⚠ | |
strverscmp⚠ | |
strxfrm⚠ | |
strxfrm_l⚠ | |
tempnam⚠ | |
tmpfile⚠ | |
tmpfile64⚠ | |
tmpnam⚠ | |
tmpnam_r⚠ | |
ungetc⚠ | |
vasprintf⚠ | |
vdprintf⚠ | |
vfprintf⚠ | |
vfscanf⚠ | |
vfscanf1⚠ | |
vprintf⚠ | |
vscanf⚠ | |
vscanf1⚠ | |
vsnprintf⚠ | |
vsprintf⚠ | |
vsscanf⚠ | |
vsscanf1⚠ |
Type Definitions
Unions
__mbstate_t__bindgen_ty_1 |